Change climate default limits to constants#14721
Merged
dgomes merged 3 commits intohome-assistant:devfrom May 31, 2018
Merged
Conversation
Min and max temp and humidity are now defined in climate __init__.py and are available for import in subclasses.
houndci-bot
reviewed
May 31, 2018
| def max_temp(self): | ||
| """Return the maximum temperature.""" | ||
| return convert_temperature(35, TEMP_CELSIUS, self.temperature_unit) | ||
| return convert_temperature(DEFAULT_MAX_TEMP, TEMP_CELSIUS, self.temperature_unit) |
There was a problem hiding this comment.
line too long (89 > 79 characters)
| def min_temp(self): | ||
| """Return the minimum temperature.""" | ||
| return convert_temperature(7, TEMP_CELSIUS, self.temperature_unit) | ||
| return convert_temperature(DEFAULT_MIN_TEMP, TEMP_CELSIUS, self.temperature_unit) |
There was a problem hiding this comment.
line too long (89 > 79 characters)
houndci-bot
reviewed
May 31, 2018
| def max_temp(self): | ||
| """Return the maximum temperature.""" | ||
| return convert_temperature(35, TEMP_CELSIUS, self.temperature_unit) | ||
| return convert_temperature(DEFAULT_MAX_TEMP, TEMP_CELSIUS, self.temperature_unit) |
There was a problem hiding this comment.
line too long (89 > 79 characters)
| def min_temp(self): | ||
| """Return the minimum temperature.""" | ||
| return convert_temperature(7, TEMP_CELSIUS, self.temperature_unit) | ||
| return convert_temperature(DEFAULT_MIN_TEMP, TEMP_CELSIUS, self.temperature_unit) |
There was a problem hiding this comment.
line too long (89 > 79 characters)
3 tasks
dgomes
requested changes
May 31, 2018
Contributor
dgomes
left a comment
There was a problem hiding this comment.
After addressing the comments LGTM
| SUPPORT_AWAY_MODE, SUPPORT_AUX_HEAT) | ||
| SUPPORT_OPERATION_MODE, SUPPORT_TARGET_TEMPERATURE, | ||
| SUPPORT_FAN_MODE, SUPPORT_SWING_MODE, SUPPORT_HOLD_MODE, | ||
| SUPPORT_AWAY_MODE, SUPPORT_AUX_HEAT, DEFAULT_MAX_TEMP, DEFAULT_MIN_TEMP) |
Contributor
There was a problem hiding this comment.
I think changes in this file are not necessary for this PR
Contributor
Author
There was a problem hiding this comment.
Right, that's for the other PR.
| """Return the maximum temperature.""" | ||
| if self._max_temp: | ||
| return self._max_temp | ||
| # Get default temp from super class |
Contributor
There was a problem hiding this comment.
This comment can be removed
dgomes
approved these changes
May 31, 2018
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description:
Min and max temp and humidity are now defined in climate __init__.py and are available for import in subclasses.
Checklist:
tox. Your PR cannot be merged unless tests pass